import request from '@/utils/request'

export function testPaperList(query) {
  return request({
    url: '/exam/testPaper/list',
    method: 'get',
    params: query
  })
}

export function testPaperInfo(id, flag, params) {
  return request({
    url: `/exam/testPaper/info/${id}/${flag}`,
    method: 'get',
    params
  })
}

export function testPaperAddOrUpdate(data) {
  return request({
    url: '/exam/testPaper/addOrUpdate',
    method: 'post',
    data
  })
}

export function testPaperDelete(id) {
  return request({
    url: '/exam/testPaper/' + id,
    method: 'delete'
  })
}
